- @narrow = true

%p= t('accounts.verify_code_intro')

= form_tag verify_code_account_path, id: 'verify-form' do
  = hidden_field_tag :id, @verification.id

  .form-group
    %label{for: "code"}= t('accounts.enter_code')
    = text_field_tag :code, params[:code], class: 'form-control'
  .form-group
    = submit_tag t('accounts.check_code'), class: 'btn btn-success'

- if params[:code].present?
  :javascript
    document.getElementById('verify-form').submit();
